package com.top.web.hooker.search;

public interface ISearch<TKey, TItem>
{
    interface SearchListener<TItem>
    {
        void onFind(TItem item);

        void onCompleted();
    }

    interface Cancelable
    {
        void cancel();
    }

    TKey getName();

    Cancelable search(CharSequence key, SearchListener<TItem> listener);

    <T> T param(String name, T def);

    void put(String name, Object value);
}
